package cn.wolfcode.luowowo.search.repositoty;

import cn.wolfcode.luowowo.search.template.HotelTemplate;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * spring-data-jpa操作接口
 *
 */
@Repository
public interface HotelTemplateRepository extends ElasticsearchRepository<HotelTemplate, Long> {


    /**
     * 通过name查询目的地对象
     * @param keyword
     * @return
     */
    HotelTemplate findByName(String keyword);

    List<HotelTemplate> findByDestName(String destName);

    List<HotelTemplate> findByDestId(Long id);
}
